auto merge of #255 : michaelsproul/cargo/missing-pkg-error, r=alexcrichton
authorbors <bors@rust-lang.org>
Tue, 29 Jul 2014 20:44:31 +0000 (20:44 +0000)
committerbors <bors@rust-lang.org>
Tue, 29 Jul 2014 20:44:31 +0000 (20:44 +0000)
commit57fc68cd11eb62b2cdb016a7dbbf976720f96e1e
treee5c2a8792581ce20ef51d6e19ef12d114a2b1a53
parent03e46e697a7efa4c46201caf69c5962f41495093
parentf65aeebf64381ca0c92a851acbf6f8c4b773ae2d
auto merge of #255 : michaelsproul/cargo/missing-pkg-error, r=alexcrichton

I've changed the error message that appears when a dependency can't be located. With my changes, mismatches between Cargo.toml dependency names and actual dependency package names are (slightly) more apparent. This doesn't change the error that appears when a dependency has an invalid source.

Example:

```toml
# Cargo.toml
...
[dependencies.foo]

path = "foo"
```

```toml
# foo/Cargo.toml
[package]

name = "not_foo"
```

Previously:

```
$ cargo build
No package named Dependency { name: foo, namespace: file:/home/michael/cargo_test, req: *, transitive: true } found
```

Now:

```
$ cargo build
No package named `foo` found (required by `bar`).
Location searched: /some/folder/not_foo
Version required: *
```

In verbose mode I think it would be also nice to print a list of packages that Cargo *does* know about. Something like: "Known packages amongst dependencies: not_foo, etc"